From 7f9a0dbe164f7c731d24c4890dde51391787e966 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Tue, 6 May 2014 22:19:12 -0400 Subject: [PATCH] Add private api to load a single module In the following commits, this function will be used to load the gtkparasite module. --- gtk/gtkmodules.c | 7 +++++++ gtk/gtkmodules.h | 1 - gtk/gtkmodulesprivate.h | 1 + 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/gtk/gtkmodules.c b/gtk/gtkmodules.c index 640be7bb55..87883e9c70 100644 --- a/gtk/gtkmodules.c +++ b/gtk/gtkmodules.c @@ -600,3 +600,10 @@ _gtk_module_has_mixed_deps (GModule *module_to_check) return result; } + +void +_gtk_modules_load_module (const gchar *name) +{ + /* We leak the ref */ + g_slist_free (load_modules (name)); +} diff --git a/gtk/gtkmodules.h b/gtk/gtkmodules.h index 29409b7041..b5a756edfe 100644 --- a/gtk/gtkmodules.h +++ b/gtk/gtkmodules.h @@ -49,7 +49,6 @@ typedef void (*GtkModuleInitFunc) (gint *argc, */ typedef void (*GtkModuleDisplayInitFunc) (GdkDisplay *display); - G_END_DECLS diff --git a/gtk/gtkmodulesprivate.h b/gtk/gtkmodulesprivate.h index 11dbebfd9d..34c30739f9 100644 --- a/gtk/gtkmodulesprivate.h +++ b/gtk/gtkmodulesprivate.h @@ -38,6 +38,7 @@ void _gtk_modules_init (gint *argc, const gchar *gtk_modules_args); void _gtk_modules_settings_changed (GtkSettings *settings, const gchar *modules); +void _gtk_modules_load_module (const gchar *name); gboolean _gtk_module_has_mixed_deps (GModule *module); -- 2.30.2